package com.jeeinc.oa.service.impl;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;
import org.springframework.transaction.annotation.Transactional;

import com.jeeinc.oa.dao.IPortletDao;
import com.jeeinc.oa.domain.Portlet;
import com.jeeinc.oa.model.Pager;
import com.jeeinc.oa.service.IPortletService;

@Service
@Transactional
public class PortletServiceImpl implements IPortletService {
	@Resource
	private IPortletDao portletDao;

	@Override
	public Portlet getPortlet(Integer id) {
		return portletDao.get(id);
	}

	@Override
	public void savePortlet(Portlet portlet) {
		portletDao.save(portlet);
	}

	@Override
	public void updatePortlet(Portlet portlet) {
		portletDao.update(portlet);
	}

	@Override
	public void deletePortlet(Portlet portlet) {
		portletDao.delete(portlet);
	}

	@Override
	public Pager getPortlets(Pager pager) {
		return portletDao.getPortlets(pager);
	}

}
